#ifndef _LOG_H_
#define _LOG_H_

#include "osal.h"

//#ifndef NDEBUG
#if 1
#ifdef __tds__
#define __log(MOD, FMT, ARGS...)						\
	do { libc_printf("<%4.4s>[%30.30s]\t", MOD, __FUNCTION__); libc_printf(FMT, ##ARGS); } while(0)
#else
#define __log(MOD, FMT, ARGS...)						\
	do { fprintf(stderr, "<%4.4s>[%30.30s]\t", MOD, __FUNCTION__); fprintf(stderr, FMT, ##ARGS); } while(0)
#endif
#else
#define __log(MOD, FMT, ARGS...)
#endif

#endif//_LOG_H_
